//
//  UserManager.h
//  EveryDay
//
//  Created by FengDongsheng on 15/6/25.
//  Copyright (c) 2015年 FengDongsheng. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "UserInfo.h"

@interface UserManager : NSObject

@property (nonatomic, strong) UserInfo     *userInfo;

+ (UserManager*)manager;

//判断用户是否登录，没登陆会弹出登录按钮
+ (BOOL)checkLogin:(UIViewController *)viewController;
//- (BOOL)checkLogin:(UIViewController *)viewController finished:(void (^)())finished;
//是否已经登录
+ (BOOL)isLogin;



//退出登录
+ (void)logout;

//登录
//- (void)updateUserInfo:(NSDictionary *)uInfo;


/**
 获取登录信息

 @param success success description
 @param failure failure description
 */
+ (void)userInfoWithSuccess:(void(^)(UserInfo *userInfo))success
                    failure:(void(^)(NSInteger code,NSString *errorMessage))failure;

@end
